package com.ssy.lingxi.order.model.dto;

import com.ssy.lingxi.common.model.dto.UserLoginCacheDTO;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.List;

/**
 * 订单支付信息缓存DTO
 * @author 万宁
 * @version 2.0.0
 * @date 2021-09-10
 */
public class PaymentCacheDTO implements Serializable {
    private static final long serialVersionUID = -1757326534766291584L;

    public PaymentCacheDTO() {
    }

    public PaymentCacheDTO(UserLoginCacheDTO loginUser, String tradeNo, BigDecimal payAmount, List<OrderPaymentDTO> payments) {
        this.memberId = loginUser.getMemberId();
        this.roleId = loginUser.getMemberRoleId();
        this.memberRoleName = loginUser.getMemberRoleName();
        this.userId = loginUser.getUserId();
        this.userName = loginUser.getUserName();
        this.userRoleName = loginUser.getUserRoleName();
        this.jobTitle = loginUser.getUserJobTitle();
        this.organization = loginUser.getUserOrgName();
        this.tradeNo = tradeNo;
        this.payAmount = payAmount;
        this.payments = payments;
    }

    /**
     * 会员Id
     */
    private Long memberId;

    /**
     * 角色Id
     */
    private Long roleId;

    /**
     * 会员角色名称
     */
    private String memberRoleName;

    /**
     * 用户Id
     */
    private Long userId;

    /**
     * 用户姓名
     */
    private String userName;

    /**
     * 用户角色名称
     */
    private String userRoleName;

    /**
     * 职位
     */
    private String jobTitle;

    /**
     * 组织机构名称
     */
    private String organization;

    /**
     * 交易订单号
     */
    private String tradeNo;

    /**
     * 支付金额
     */
    private BigDecimal payAmount;

    /**
     * 支付记录
     */
    private List<OrderPaymentDTO> payments;

    public Long getMemberId() {
        return memberId;
    }

    public void setMemberId(Long memberId) {
        this.memberId = memberId;
    }

    public Long getRoleId() {
        return roleId;
    }

    public void setRoleId(Long roleId) {
        this.roleId = roleId;
    }

    public String getMemberRoleName() {
        return memberRoleName;
    }

    public void setMemberRoleName(String memberRoleName) {
        this.memberRoleName = memberRoleName;
    }

    public Long getUserId() {
        return userId;
    }

    public void setUserId(Long userId) {
        this.userId = userId;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    public String getUserRoleName() {
        return userRoleName;
    }

    public void setUserRoleName(String userRoleName) {
        this.userRoleName = userRoleName;
    }

    public String getJobTitle() {
        return jobTitle;
    }

    public void setJobTitle(String jobTitle) {
        this.jobTitle = jobTitle;
    }

    public String getOrganization() {
        return organization;
    }

    public void setOrganization(String organization) {
        this.organization = organization;
    }

    public String getTradeNo() {
        return tradeNo;
    }

    public void setTradeNo(String tradeNo) {
        this.tradeNo = tradeNo;
    }

    public BigDecimal getPayAmount() {
        return payAmount;
    }

    public void setPayAmount(BigDecimal payAmount) {
        this.payAmount = payAmount;
    }

    public List<OrderPaymentDTO> getPayments() {
        return payments;
    }

    public void setPayments(List<OrderPaymentDTO> payments) {
        this.payments = payments;
    }
}
